﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using LibraryO2S;

public partial class Administrator_AddHotline : System.Web.UI.Page
{
    tblHotline hotline = new tblHotline();
    protected void Page_Load(object sender, EventArgs e)
    {

    }

    protected void btnSubmit_Click(object sender, EventArgs e)
    {
        string name = txtName.Text;
        string phone = txtphone.Text;
        string yahoo = txtyahoo.Text;
        string skype = txtskype.Text;

        try
        {
            if (hotline.AddHotline(name,phone,yahoo,skype,""))
            {
                divMessage.InnerHtml = O2S_Message.Success("System", "Successfully");

            }

        }
        catch (Exception ex)
        {

            divMessage.InnerHtml = O2S_Message.Error("System", "Error" + ex.Message);
        }
    }
}